package com.qf.controller;

import com.qf.feign.TestFeign;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.beans.factory.annotation.Value;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

/*
 *@Description:
 *@author:刘哥
 *@Date:86180 2022/10/25 20:40
 */
@RestController
@RequestMapping("/customer")
public class CustomerController {
    @Autowired
    private TestFeign testFeign;
//    从配置文件中读取
    @Value("${version}")
    private String version;
    @RequestMapping("/t1")
    public String t1(){
        String str = testFeign.hello();
        return str;
    }
    @RequestMapping("/t2")
    public String t2(){
        return version;
    }
}
